package com.loby.data.code.pojo;


import lombok.Data;

import java.io.Serializable;
import java.util.Objects;

@Data
public class TCodeAdministrativeDivision implements Serializable {

  private String pkDivisionCode;
  private String divisionName;
  private String fullPhonetic;
  private String fkParentCode;
  private String codePath;
  private String namePath;
  private long level;
  private String alphabetCode;



  public String getPkDivisionCode() {
    return pkDivisionCode;
  }

  public void setPkDivisionCode(String pkDivisionCode) {
    this.pkDivisionCode = pkDivisionCode;
  }


  public String getDivisionName() {
    return divisionName;
  }

  public void setDivisionName(String divisionName) {
    this.divisionName = divisionName;
  }


  public String getFullPhonetic() {
    return fullPhonetic;
  }

  public void setFullPhonetic(String fullPhonetic) {
    this.fullPhonetic = fullPhonetic;
  }


  public String getFkParentCode() {
    return fkParentCode;
  }

  public void setFkParentCode(String fkParentCode) {
    this.fkParentCode = fkParentCode;
  }


  public String getCodePath() {
    return codePath;
  }

  public void setCodePath(String codePath) {
    this.codePath = codePath;
  }


  public String getNamePath() {
    return namePath;
  }

  public void setNamePath(String namePath) {
    this.namePath = namePath;
  }


  public long getLevel() {
    return level;
  }

  public void setLevel(long level) {
    this.level = level;
  }


  public String getAlphabetCode() {
    return alphabetCode;
  }

  public void setAlphabetCode(String alphabetCode) {
    this.alphabetCode = alphabetCode;
  }

  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    TCodeAdministrativeDivision that = (TCodeAdministrativeDivision) o;
    return level == that.level &&
            pkDivisionCode.equals(that.pkDivisionCode) &&
            divisionName.equals(that.divisionName) &&
            Objects.equals(fullPhonetic, that.fullPhonetic) &&
            Objects.equals(fkParentCode, that.fkParentCode) &&
            Objects.equals(codePath, that.codePath) &&
            Objects.equals(namePath, that.namePath) &&
            Objects.equals(alphabetCode, that.alphabetCode) ;
  }

  @Override
  public int hashCode() {
    return Objects.hash(pkDivisionCode, divisionName, fullPhonetic, fkParentCode, codePath, namePath, level, alphabetCode);
  }
}
